#ifndef GENOSAGE_H
#define GENOSAGE_H

#include <QObject>
#include <QGraphicsItem>

#include "GenoSageBaseClasses/genosagebasewidget.h"

//Forward declarations to avoid circular dependencies
class VisBaseWidget;
class SageVis;
class GenoSageBaseWidget;

/**GenoSage class.
  * GenoSage manages genome visualization widgets in SageNext.
  * I may eventually have this class inherit from a base 'manager' class, allowing programmers to manage groups of widgets
  *  with common data elements.
  * This class will have many similar operations to SAGEVis, but I decided to make this a separate class.
  * I think it may be necessary to provide specific classes of visWidgets with independent manager classes.
  * GenoSAGE visWidgets may need biologically relevant connection types or operations, and if I store them
  * here then I have both quick access to these classes and the opportunity to implement Geno-SAGE specific
  * operations on them.
  * This is the theory.  We'll see how it plays out in practice.
  * At the moment GenoSage just stores pointers to GenoSage Widgets.
*/
class GenoSage : public QGraphicsWidget
{
    Q_OBJECT
public:
    /** GenoSage constructor.
      * Constructor takes SageVis as parent
      */
    explicit GenoSage(SageVis *parent = 0);

    /** addWidget(  QPointer<VisBaseWidget> newWidget ).
      * @param QPointer<VisBaseWidget> newWidget.  New widget for genosage to manage.
      * Passes GenoSage a new vis widget to manage.
      * Question:  why store VisBaseWidgets and not GenoSageBaseWidgets.
      */
    void addWidget( QPointer<VisBaseWidget> newWidget );


signals:
    
public slots:

private:
    QPointer<SageVis> sageVisParent;/**< sageVisParent points to the SageVis parent object*/
    QList< QPointer< VisBaseWidget > > genoSageWidgets; /**< genoSageWidgets stores a list of managed vis widgets currently running */
    
};

#endif // GENOSAGE_H
